/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package br.com.foxline.manager.create;

import br.com.foxline.model.Registration;
import br.com.foxline.service.RegistrationService;
import java.io.Serializable;
import java.util.Collection;
import java.util.Collections;
import java.util.List;
import javax.ejb.EJB;
import javax.faces.bean.ManagedBean;
import javax.faces.bean.ViewScoped;

/**
 *
 * @author luciano
 */
@ManagedBean
@ViewScoped
public class ManagerIndexRegistration implements  Serializable{
    
    @EJB
    RegistrationService registrationService;
    
    public List<Registration> averbacoes(){
        List<Registration> registrations = registrationService.findAll();
        Collections.reverse(registrations);
        return  registrations;
    }
    
}
